package cn.iocoder.yudao.module.book.controller.admin.homeworks.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.*;
import javax.validation.constraints.*;

@Schema(description = "管理后台 - 作业新增/修改 Request VO")
@Data
public class HomeworksSaveReqVO {

    @Schema(description = "作业id", requiredMode = Schema.RequiredMode.REQUIRED, example = "10022")
    private Integer homeworkId;

    @Schema(description = "班级id", requiredMode = Schema.RequiredMode.REQUIRED, example = "1871")
    @NotNull(message = "班级id不能为空")
    private Integer classesId;

    @Schema(description = "标题", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "标题不能为空")
    private String title;

    @Schema(description = "日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "日期不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate date;

    @Schema(description = "作业要求", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotEmpty(message = "作业要求不能为空")
    private String requirement;

    @Schema(description = "作业内容", requiredMode = Schema.RequiredMode.REQUIRED, example = "你说的对")
    @NotEmpty(message = "作业内容不能为空")
    private String description;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "绘本集ID列表", example = "[1, 2, 3]")
    private List<Integer> collectionIds;

}